
import AbsMenu from '../absmenu.js'

class SysToolMenu extends AbsMenu.AbsMenu {
    constructor(map, item) {
        super(map, item);
    }

    act2Click() {
        console.log("SysToolMenu-----+" + this.menuSubItem);
        switch (this.menuSubItem) {
            case 'option':
                this.setSysOption();
                break;

            case 'script':
                break;

            default:
                break;
        }
    }

    setSysOption() {
        let t = window.SystemSetting.value;
        if (t && !t.visible) {
            t.visible = true;
            t.mapctrl = this.map;
        }
    }
}

export default { SysToolMenu }

